package com.example.JcGQS.enums;

/**
 * 采购状态枚举类
 * @author 末日
 * @date 2023年11月8日
 */
public enum ProjectStateEnum {
    PROJECT_1(1,"兴惠包装项目"),
    PROJECT_2(2,"逸鹏络筒项目"),
    PROJECT_3(3,"恒力络筒项目"),
    PROJECT_4(4,"逸鹏包装项目"),
    PROJECT_5(5,"逸景络筒项目"),
    PROJECT_6(6,"逸景包装项目"),
    PROJECT_7(7,"恒力接布项目"),
    PROJECT_8(8,"恒力包装项目");



    private Integer value;
    private String state;
    public Integer getValue() {
        return value;
    }
    /**
     * @return the state
     */
    public String getState() {
        return state;
    }
    ProjectStateEnum(Integer value, String state) {
        this.value = value;
        this.state = state;
    }

    public static String getDescriptionByCode(Integer value) {
        for (ProjectStateEnum status : ProjectStateEnum.values()) {
            if (status.value.equals(value)) {
                return status.getState();
            }
        }
        return null; // 或者抛出异常，表示未找到对应的枚丬值
    }
}
